import http from './http.js';

http.interceptor.request = (config) => {
	
    //添加通用参数
	
    // #ifdef  MP-WEIXIN
		config.header.Authorization = uni.getStorageSync('token'); 
	// #endif
	
    // #ifdef  MP-ALIPAY
		// config.data['provider'] = 'ALIPAY';
    // #endif

    return config;
}; //设置请求结束后拦截器

http.interceptor.response = (response) => {
    //判断返回状态 执行相应操作
    return response;
};

export default http;
